package cn.edu.nwpu.warehousemanagement.controller;

import cn.edu.nwpu.warehousemanagement.pojo.Result;
import cn.edu.nwpu.warehousemanagement.pojo.dto.PredictVO;
import cn.edu.nwpu.warehousemanagement.service.InventoryRecordService;
import cn.edu.nwpu.warehousemanagement.service.PredictService;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/api/predict")
@RequiredArgsConstructor
public class PredictController {
    private final PredictService predictService;

    @GetMapping("/{id}")
    public Result<PredictVO> getPredictByProductId(@PathVariable String id){return predictService.getPredictByProductId(id);}
}
